#####################################################
###Appendix Figure A1, Missing ######################
#####################################################

logit1 <- glm(missing ~ unauthorised + age + gender +education +msp + econ_status, data = dat, family = "binomial")
logit2 <- glm(missing ~ violent + age + gender +education +msp+ econ_status, data = dat, family = "binomial")
logit3 <- glm(missing ~ arrest + age + gender +education +msp+ econ_status, data = dat, family = "binomial")
dwplot(list(logit1, logit2, logit3))


fig_A1A<-dwplot(list(logit1, logit2, logit3),
                vline = geom_vline(xintercept = 0, colour = "grey60", linetype = 2)) %>% # plot line at zero _behind_ coefs
  relabel_predictors(c(unauthorised = "Unauthorized",                       
                       age = "Age", 
                       gender = "Male", 
                       education = "Education", 
                       msp = "Moscow/StP", 
                       econ_status= "Income", 
                       violent= "Violent",
                       arrest = "Arrests")) +
  theme_bw() + xlab("Coefficient Estimate") + ylab("") +
  geom_vline(xintercept = 0, colour = "grey60", linetype = 2) +
  ggtitle("Non-Response, 2020 Survey") +
  theme(plot.title = element_text(face="bold"),
        legend.position = c(0.007, 0.01),
        legend.justification = c(0, 0), 
        legend.background = element_rect(colour="grey80"),
        legend.title = element_blank()) 
fig_A1A

ggsave(height=5,
       width=7,
       "Figures/fig_A1A.png")
